package com.example.jobback.mapper;

import com.example.jobback.po.Deliver;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @InterfaceName: DeliverMapper
 * @Description:投递Mapper
 * @Author: lhb
 * @Date: 2025/7/16
 */
@Mapper
public interface DeliverMapper {
    int deliverPosition(Deliver deliver);

    Deliver getDeliverByUnique(Deliver deliver);

    void insert(Deliver deliver);

    int update(Deliver deliver);

    List<Deliver> getDeliverBySeekerUserId(@Param("userId") Long userId);

    List<Deliver> getDeliversByRecruiterUserId(@Param("userId") Long recruiterUserId, @Param("interview") Boolean interview);

    List<Deliver> getInterviewsBySeekerUserId(@Param("userId") Long userId);

    Deliver getDeliverByBothUserId(@Param("recruiterUserId") Long recruiterUserId,
                                   @Param("seekerUserId") Long seekerUserId);

    Long getResumeDelivers();

    void deleteByRecruiterUserId(@Param("userId") Long deleteUserId);
}
